package com.ruoyi.fly.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;
import org.hibernate.validator.constraints.Length;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.time.LocalDateTime;

/**
 * 实体类 店铺表
 */
@Data
@NoArgsConstructor
@ToString(callSuper = true)
@Accessors(chain = true)
@ApiModel(value = "Store", description = "店铺表")
@AllArgsConstructor
public class Store implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "店铺表主键id")
    private String id;

    @ApiModelProperty(value = "会员id")
    private String mid;

    private String tenantCode;

    /**
     * 店铺名称
     */
    @ApiModelProperty(value = "店铺名称")
    @Length(max = 200, message = "店铺名称长度不能超过200")
    private String storeName;

    /**
     * logo
     */
    @ApiModelProperty(value = "logo")
    @Length(max = 500, message = "logo长度不能超过500")
    private String logo;

    /**
     * 发货地址
     */
    @ApiModelProperty(value = "发货地址")
    @Length(max = 500, message = "发货地址长度不能超过500")
    private String shipAddress;

    /**
     * 店铺简介
     */
    @ApiModelProperty(value = "店铺简介")
    @Length(max = 500, message = "店铺简介长度不能超过500")
    private String remark;

    /**
     * 注册手机号
     */
    @ApiModelProperty(value = "注册手机号")
    @NotEmpty(message = "注册手机号不能为空")
    @Length(max = 32, message = "注册手机号长度不能超过32")
    private String mobile;

    /**
     * 退货地址
     */
    @ApiModelProperty(value = "退货地址")
    @Length(max = 500, message = "退货地址长度不能超过500")
    private String refundAddress;

    /**
     * 退货联系电话
     */
    @ApiModelProperty(value = "退货联系电话")
    @Length(max = 32, message = "退货联系电话长度不能超过32")
    private String refundTel;

    /**
     * 被访问的次数
     */
    @ApiModelProperty(value = "被访问的次数")
    private Long frequency;

    /**
     * 退货联系人
     */
    @ApiModelProperty(value = "退货联系人")
    @Length(max = 32, message = "退货联系人长度不能超过32")
    private String refundContact;

    /**
     * 店铺类型:1汽修店，2保养店，3美容店，4贴膜店，5洗车店，6轮胎更换店，7救援店，8加油站
     */
    @ApiModelProperty(value = "店铺类型:1汽修店，2保养店，3美容店，4贴膜店，5洗车店，6轮胎更换店，7救援店，8加油站")
    @NotNull(message = "店铺类型:1汽修店，2保养店，3美容店，4贴膜店，5洗车店，6轮胎更换店，7救援店，8加油站")
    private String storeType;

    /**
     * 是否自动发送退货地址给买家 0否 1是
     */
    @ApiModelProperty(value = "是否自动发送退货地址给买家 0否 1是")
    @NotNull(message = "是否自动发送退货地址给买家 0否 1是不能为空")
    private Integer isAutoSendRefundAddress;

    @ApiModelProperty(value = "店铺状态 1=正常 2=关闭")
    private Long  storeState;

    /**
     * 经度
     */
    @ApiModelProperty(value = "经度")
    private String longitude;
    /**
     * 纬度
     */
    @ApiModelProperty(value = "纬度")
    private String latitude;
    @ApiModelProperty(value = "注册人注册省份")
    private String province;

    @ApiModelProperty(value = "注册人注册市县")
    private String city;

    @ApiModelProperty(value = "注册人注册区")
    private String area;

    @ApiModelProperty(value = "注册人")
    private String registerUser;


    @ApiModelProperty(value = "注册人注册省份")
    private String provinceCode;

    /**
     * 所在市代码
     */
    @ApiModelProperty(value = "所在市代码")
    private String cityCode;


    /**
     * 所在区代码
     */
    @ApiModelProperty(value = "所在区代码")
    private String areaCode;

    @ApiModelProperty(value = "地址详情")
    private String address;

    @ApiModelProperty(value = "订单数量")
    private Integer orderQuantity;
    /**
     * 到期时间
     */
    @ApiModelProperty(value = "到期时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    private String expirationTime;
    /**
     * 联系电话
     */
    @ApiModelProperty(value = "联系电话")
    private String telephone;

    /**
     * 营业时间
     */
    @ApiModelProperty(value = "营业时间")
    private String businessHours;
    /**
     * 店面照
     */
    @ApiModelProperty(value = "店面照")
    private String storefrontImg;

    /**
     * 店面背景图
     */
    @ApiModelProperty(value = "背景图")
    private String backgroundImg;

    /**
     * 营业额
     */
    @ApiModelProperty(value = "营业额")
    private BigDecimal turnover;


    private Integer userType;
    /**
     * 评分
     */
    @ApiModelProperty(value = "评分")
    private Integer score;

    /**
     * 1=删除 0=正常
     */
    @ApiModelProperty(value = "1=删除 0=正常")
    private Integer isDelete;

    @ApiModelProperty(value = "审核人")
    private Long applyUser;

    @ApiModelProperty(value = "审核失败原因")
    private String reason;

    @ApiModelProperty(value = "0=审核中 1=申请通过 2=申请失败")
    private Integer applyType;

    /**
     * 创建时间
     */
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(shape = JsonFormat.Shape.NUMBER, pattern = "yyyy-MM-dd HH:mm:ss")
    private String createTime;

    /**
     * 更新时间
     */
    @ApiModelProperty(value = "更新时间")
    @JsonFormat(shape = JsonFormat.Shape.NUMBER, pattern = "yyyy-MM-dd HH:mm:ss")
    private String updateTime;

    /**
     * 创建人
     */
    @ApiModelProperty(value = "创建人")
    private Long createUser;

    /**
     * 更新人
     */
    @ApiModelProperty(value = "更新人")
    private Long updateUser;

}
